package com.ruoyi.project.modules.parameter.service;

import java.util.List;

import com.ruoyi.project.modules.interfaceinfo.request.BffParamReq;
import com.ruoyi.project.modules.interfaceinfo.request.VirtualUsageParamReq;
import com.ruoyi.project.modules.parameter.domain.InterfaceParamsFieldRelation;
import com.ruoyi.project.modules.parameter.domain.ParamsFieldRelation;
import com.ruoyi.project.modules.table.domain.TableInfo;

/**
 * 数据集下面字段关系Service接口
 * 
 * @author smallrain
 * @date 2021-10-30
 */
public interface IParamsFieldRelationService 
{
    /**
     * 查询数据集下面字段关系
     * 
     * @param id 数据集下面字段关系主键
     * @return 数据集下面字段关系
     */
    public ParamsFieldRelation selectParamsFieldRelationById(Long id);

    /**
     * 查询数据集下面字段关系列表
     * 
     * @param paramsFieldRelation 数据集下面字段关系
     * @return 数据集下面字段关系集合
     */
    public List<ParamsFieldRelation> selectParamsFieldRelationList(ParamsFieldRelation paramsFieldRelation);

    /**
     * 新增数据集下面字段关系
     * 
     * @param paramsFieldRelation 数据集下面字段关系
     * @return 结果
     */
    public int insertParamsFieldRelation(ParamsFieldRelation paramsFieldRelation);

    /**
     * 修改数据集下面字段关系
     * 
     * @param paramsFieldRelation 数据集下面字段关系
     * @return 结果
     */
    public int updateParamsFieldRelation(ParamsFieldRelation paramsFieldRelation);

    /**
     * 批量删除数据集下面字段关系
     * 
     * @param ids 需要删除的数据集下面字段关系主键集合
     * @return 结果
     */
    public int deleteParamsFieldRelationByIds(String ids);

    /**
     * 删除数据集下面字段关系信息
     * 
     * @param id 数据集下面字段关系主键
     * @return 结果
     */
    public int deleteParamsFieldRelationById(Long id);

    void saveParamsField(ParamsFieldRelation paramsFieldRelation);

    List<TableInfo> tableList(Long interfaceDataListId);

    void saveVirtualUsageParam(VirtualUsageParamReq virtualUsageParamReq);

    void saveBffParam(BffParamReq bffParamReq, List<Long> interfaceParamsFieldRelationIds, List<Long> paramsFieldRelationIds);
    void saveDubboParam(BffParamReq bffParamReq, List<Long> interfaceParamsFieldRelationIds, List<Long> paramsFieldRelationIds);

    void removeParamsField(Long id, InterfaceParamsFieldRelation interfaceParamsFieldRelation);

    List<ParamsFieldRelation> selectParamsFieldRelationListByDataRelationId(List<Long> dataRelationIds, String dataRelationType);

    void saveGroupParam(BffParamReq bffParamReq, List<Long> interfaceParamsFieldRelationIds, List<Long> paramsFieldRelationIds);
}
